﻿#include "mainwindow.h"
#include <QApplication>
#include "serialselectwidget.h"

int main(int argc, char *argv[])
{
    QApplication a(argc, argv);

    QString sComName = "";

    QSerialSelectWidget* pSerialWidget = new QSerialSelectWidget();
    if(pSerialWidget->exec() == QDialog::Accepted)
    {
        sComName = pSerialWidget->m_sSelectComName;
        delete pSerialWidget;
    }
    else
    {
        delete pSerialWidget;
        return 0;
    }

    MainWindow w(sComName);
    w.show();

    return a.exec();
}
